//
// Decompiled by Jadx - 375ms
//
package me.plusne.GreenDao.dao;

import android.database.Cursor;
import android.database.sqlite.SQLiteStatement;
import androidx.activity.b;
import fm.g;
import org.greenrobot.greendao.database.DatabaseStatement;
import x.a;
import x.d;

public final class LookHomeJsonDao extends a<g, Long> {
    public static final String TABLENAME = "LOOK_HOME_JSON";

    public class Properties {
        public static final d AvatarName;
        public static final d Ext;
        public static final d Num;
        public static final d Time;
        public static final d Id = new d(0, Long.class, "id", true, "_id");
        public static final d From = new d(1, String.class, "From", false, "FROM");
        public static final d To = new d(2, String.class, "to", false, "TO");
        public static final d UserIdEcp = new d(3, String.class, "UserIdEcp", false, "USER_ID_ECP");
        public static final d Signature = new d(4, String.class, "Signature", false, "SIGNATURE");

        static {
            Class cls = Long.TYPE;
            Time = new d(5, cls, "time", false, "TIME");
            Ext = new d(6, cls, "ext", false, "EXT");
            Num = new d(7, Integer.TYPE, "num", false, "NUM");
            AvatarName = new d(8, String.class, "avatarName", false, "AVATAR_NAME");
        }
    }

    public LookHomeJsonDao(g.a aVar) {
        super(aVar);
    }

    public static void createTable(org.greenrobot.greendao.database.Database aVar, boolean z) {
        aVar.d("CREATE TABLE " + (z ? "IF NOT EXISTS " : "") + "\"LOOK_HOME_JSON\" (\"_id\" INTEGER PRIMARY KEY AUTOINCREMENT ,\"FROM\" TEXT,\"TO\" TEXT,\"USER_ID_ECP\" TEXT,\"SIGNATURE\" TEXT,\"TIME\" INTEGER NOT NULL ,\"EXT\" INTEGER NOT NULL ,\"NUM\" INTEGER NOT NULL ,\"AVATAR_NAME\" TEXT);");
    }

    public static void dropTable(org.greenrobot.greendao.database.Database aVar, boolean z) {
        String str;
        StringBuilder sb = new StringBuilder("DROP TABLE ");
        if (z) {
            str = "IF EXISTS ";
        } else {
            str = "";
        }
        b.v(sb, str, "\"LOOK_HOME_JSON\"", aVar);
    }

    public final void a(SQLiteStatement sQLiteStatement, Object obj) {
        g gVar = (g) obj;
        sQLiteStatement.clearBindings();
        Long l = gVar.a;
        if (l != null) {
            sQLiteStatement.bindLong(1, l.longValue());
        }
        String str = gVar.b;
        if (str != null) {
            sQLiteStatement.bindString(2, str);
        }
        String str2 = gVar.c;
        if (str2 != null) {
            sQLiteStatement.bindString(3, str2);
        }
        String str3 = gVar.d;
        if (str3 != null) {
            sQLiteStatement.bindString(4, str3);
        }
        String str4 = gVar.e;
        if (str4 != null) {
            sQLiteStatement.bindString(5, str4);
        }
        sQLiteStatement.bindLong(6, gVar.f);
        sQLiteStatement.bindLong(7, gVar.g);
        sQLiteStatement.bindLong(8, gVar.h);
        String str5 = gVar.i;
        if (str5 != null) {
            sQLiteStatement.bindString(9, str5);
        }
    }

    public final void b(Object obj, DatabaseStatement cVar) {
        g gVar = (g) obj;
        cVar.k();
        Long l = gVar.a;
        if (l != null) {
            cVar.j(1, l.longValue());
        }
        String str = gVar.b;
        if (str != null) {
            cVar.i(2, str);
        }
        String str2 = gVar.c;
        if (str2 != null) {
            cVar.i(3, str2);
        }
        String str3 = gVar.d;
        if (str3 != null) {
            cVar.i(4, str3);
        }
        String str4 = gVar.e;
        if (str4 != null) {
            cVar.i(5, str4);
        }
        cVar.j(6, gVar.f);
        cVar.j(7, gVar.g);
        cVar.j(8, gVar.h);
        String str5 = gVar.i;
        if (str5 != null) {
            cVar.i(9, str5);
        }
    }

    public final Long c(Object obj) {
        g gVar = (g) obj;
        if (gVar != null) {
            return gVar.a;
        }
        return null;
    }

    public final Object d(Cursor cursor) {
        return new g(cursor.isNull(0) ? null : Long.valueOf(cursor.getLong(0)), cursor.isNull(1) ? null : cursor.getString(1), cursor.isNull(2) ? null : cursor.getString(2), cursor.isNull(3) ? null : cursor.getString(3), cursor.isNull(4) ? null : cursor.getString(4), cursor.getLong(5), cursor.getLong(6), cursor.getInt(7), cursor.isNull(8) ? null : cursor.getString(8));
    }

    public final Long e(Cursor cursor) {
        if (cursor.isNull(0)) {
            return null;
        }
        return Long.valueOf(cursor.getLong(0));
    }

    public final Long f(long j, Object obj) {
        ((g) obj).a = Long.valueOf(j);
        return Long.valueOf(j);
    }
}
